import Vue from 'vue'
import App from './App.vue'
// 引入elementui
import   ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
Vue.use(ElementUI)

// 引入axios
import axios from "axios";
// 配置axios的基路径
// axios.defaults.baseURL = 'http://localhost:8080/'
axios.defaults.baseURL = '/api'
// 允许携带凭证
// axios.defaults.withCredentials = true;
// 挂载到当前的Vue实例
Vue.prototype.$axios = axios

Vue.config.productionTip = false

// 引入路由的js文件
import router from './router/index.js'

new Vue({
  render: function (h) { return h(App) },
  // 将路由对象挂载到vue实例上
  router
}).$mount('#app')